<%-- 
    Document   : list
    Created on : 4-dec-2009, 1:19:51
    Author     : Simon
--%>

<%@include file="../header.jsp" %>

<h1>Medication tasks</h1>
<c:if test="${empty tasks}">
    No uncompleted medication tasks found.
</c:if>
<c:if test="${!empty tasks}">
    <table class="data">
        <thead>
            <tr>
                <td>General Practitioner</td>
                <td>Medication</td>
                <td>Status</td>
                <td>Tijdstip</td>
                <td></td>
            </tr>
        </thead>
        <c:forEach var="task" items="${tasks}" >
            <tr>
                <td>${task.prescription.gp.name}</td>
                <td>${task.prescription.medication.name}</td>
                <td>${task.status.title}</td>
                <td>${task.taskTime}</td>
                <td>
                    <a href="${pageContext.request.contextPath}/patient/medicationtask/show?id=${task.id}">Take medication</a>
                </td>
            </tr>
        </c:forEach>
    </table>
</c:if>

<%@include file="../footer.jsp" %>